package com.gitee.dupe.authority.entity;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.gitee.dolt.core.base.entity.Entity;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.experimental.Accessors;
import org.hibernate.validator.constraints.Length;

import javax.validation.constraints.NotBlank;

/**
 * <p>
 *
 * </p>
 *
 * @author LYH
 * @since 2020-06-30
 */
@Data
@Accessors(chain = true)
@ApiModel(value = "Org", description = "组织架构")
@TableName("b_org")
public class Org extends Entity<Long> {

    /**
     * 名称
     */
    @ApiModelProperty(value = "名称", required = true)
    @NotBlank
    @Length(max = 255)
    @TableField(value = "name")
    private String name;

    /**
     * 名称
     */
    @ApiModelProperty(value = "父级")
    @Length(max = 255)
    @TableField(value = "parent_id")
    private String parentId;

    /**
     * 备注
     */
    @ApiModelProperty(value = "备注")
    @Length(max = 255)
    @TableField(value = "remark")
    private String remark;


}
